Remove LongBridge fractional share support#67
Conversation
66abe0e to
b1af26a
Compare
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 66abe0eae9
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if allow_fractional | ||
| else _floor_whole_share_quantity(quantity) | ||
| ), | ||
| quantity=_floor_whole_share_quantity(quantity), |
There was a problem hiding this comment.
Normalize sweep sell quantity before funding checks
Flooring every submitted order quantity here introduces a mismatch with the cash-sweep path in execute_rebalance_cycle, which still computes available_sweep_cash, dry-run sale proceeds, and quantity text from the unfloored sellable_quantities value. With legacy fractional holdings (for example 3.75 shares), the strategy can conclude a sweep sale will fund a whole-share buy, but the actual submitted order is truncated to 3 shares, so the follow-on buy may be impossible (and dry-run can overstate executable cash). Please normalize sweep quantities to whole shares before funding/proceeds/log decisions so those decisions match what is actually submitted.
Useful? React with 👍 / 👎.
LongBridge is now whole-share only.
Changes:
Validation: